package com.start.cms.entity;

import com.alibaba.fastjson2.JSONObject;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.start.common.dic.DictMapper;
import com.start.common.entity.StartBaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@TableName("start_cms_article")
public class StartCmsArticleEntity extends StartBaseEntity {
    @Schema(name = "文章标题")
    private String articleTitle;
    @Schema(name = "栏目")
    @DictMapper(value = "栏目", mapperTable = "start_cms_category", mapperLabel = "title", mapperValue = "id")
    private String categoryId;
    @Schema(name = "文章标记")
    private String articleTag;
    @Schema(name = "文章描述")
    private String articleDescribe;
    @Schema(name = "搜索关键字")
    private String articleKeyWorld;
    @Schema(name = "文章封面")
    private String articleCover;
    @Schema(name = "文章内容")
    private String articleContent;
    @Schema(name = "作者")
    private String articleAuthor;
    @Schema(name = "来源")
    private String articleSource;
    @Schema(name = "文章浏览量")
    private Integer articlePv;
    @Schema(name = "虚拟页面浏览量")
    private Integer virtualPv;
    @Schema(name = "用户浏览量")
    private Integer articleUv;
    @Schema(name = "虚拟用户量")
    private Integer virtualUv;
    @Schema(name = "发布状态", description = "0 未发布 1 已发布")
    private Integer articleState;
    @Schema(name = "审核状态", description = "-1审核未通过 0 待审核 1 审核通过")
    private Integer auditStatus;
    @Schema(name = "审核时间")
    private LocalDateTime auditTime;
    @Schema(name = "审核未通过原因")
    private String auditFailReason;
    @Schema(name = "审核人")
    private String auditUserId;
    @Schema(name = "发布时间")
    private LocalDateTime articleReleaseTime;
    @Schema(name = "文章自定义序号", description = "数值越小越靠前")
    private Integer articleSort;
    @TableLogic
    private Integer articleDelFlag;

    @Schema(name = "业务id")
    private String businessId;

    @Schema(name = "文章扩展信息")
    private JSONObject articleProp;

}
